package com.zpark.beans;

import java.io.Serializable;

/**
 * @PackageName: com.zpark.beans
 * @ClassName: Student
 * @Description:
 * @author: RZS
 * @date: 2023/3/28  14:41
 */
public class Student implements Serializable {
    private User user;

//    public Student() {
//        System.out.println("Student的无参构造器");
//    }

    public Student(User user) {
        System.out.println("执行Student的带参数构造器");
        this.user = user;
    }

//    public void setMyUser(User user) {
//        System.out.println("Student的setUser方法");
//        this.user = user;
//    }


//    public void setUser(User user) {
//        this.user = user;
//    }

    public void stuOut(){
        System.out.println("Student的stuOut方法执行");
        user.out();
    }
}
